package com.sx.service;

import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.sql.SQLException;
import java.util.ArrayList;
import java.util.List;

import org.apache.commons.dbutils.QueryRunner;
import org.apache.commons.dbutils.handlers.MapListHandler;

import com.dfec.model.Msg;
import com.dfec.utils.DruidPlugin;
import com.dfec.utils.StringUtils;


/**
 * Servlet implementation class WarningServlet
 * @param <T>
 */
public class AppVersionService {
	QueryRunner qr=new QueryRunner(DruidPlugin.getDataSource());
	List<Object> list=null;
    private String sql ="";


	public List<Object> getVersion(String appname) throws SQLException {
		// TODO Auto-generated method stub
		sql="select * from d_apk_version where code='"+appname+"'";
		list=new ArrayList<>();
    	list.add(qr.query(sql, new  MapListHandler()));
    	return list;
	}


}